#ifndef CGUIGame_H_INCLUDED
#define CGUIGame_H_INCLUDED

#include "LON.h"

class CMinionNode;
class CStateGame;

class CGUIGame
{
  public:
    friend class CStateGame;

    //! Constructor
    CGUIGame(CStateGame * state);

    virtual ~CGUIGame();

    //! Init method before displaying UI
    virtual void init();

    //! This method will be called for every frame
    //! DEPRECIATED: Use Individual update for better management
    virtual void update();

    //! Show/Hide all GUI Elements
    virtual void setVisible(bool visible);

    //! This is the method for GUI Events sent from Event Receiver
    virtual bool onGUIEvent(const SEvent& event);

    //! Update Minion Display
    void updateMinion();

    //! Update Delay Display
    void updateDelay(vector <CMinionNode*> & minionList);

  protected:
    CStateGame * state;
    IGUIEnvironment * env;

    //! This main parent is used to hide / show all elements
    IGUITab * parent;

    //! TODO: These should be extended so that each state has thier own
    //! GUI settings

    IGUIStaticText *txtName;
    IGUIStaticText *txtLvl;
    IGUIStaticText *txtAtk;
    IGUIStaticText *txtDef;
    IGUIStaticText *txtMAtk;
    IGUIStaticText *txtMDef;
    IGUIStaticText *txtHP;
    IGUIStaticText *txtMP;

    IGUIStaticText * dispDelay;
    vector <IGUIStaticText*> listDelay;

  private:
    s32 dispDelayDown;
    enum BUTTON_ID
    {
      BTN_ATTACK,
      BTN_MOVE,
      BTN_CANCEL,
      BTN_SPELL,
      BTN_ABILITY_1,
      BTN_ABILITY_2,
      BTN_ABILITY_3,
      BTN_POPSTATE,

    };
};

#endif // CGUIGame_H_INCLUDED
